/*
*Copyright (c) Nikhil Jain.
*Project ICARUS, communications and 
*artificial intelligence.
*/



/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
 */
package javadrone.statedata;

//~--- non-JDK imports --------------------------------------------------------

import javadrone.Sensor;

//~--- JDK imports ------------------------------------------------------------

import java.io.Serializable;

/**
 *
 * @author Nikzzay
 * install in both client and server
 */
public class AerialStateData extends StateData<AerialStateData.AerialState> {
    private static final Sensor DESCRIPTOR = Sensor.NAV_STATE;

    public AerialStateData(AerialStateData.AerialState as) {
        super(as, DESCRIPTOR);
    }

    @Override
    public String toString() {
        return "BOOT DATA: " + getData().toString();
    }

    public static class AerialState implements Serializable {
        private boolean isHovering, isLanding;

        public AerialState(boolean isHovering, boolean isLanding) {
            this.isHovering = isHovering;
            this.isLanding  = isLanding;
        }

        public boolean isHovering() {
            return isHovering;
        }

        public boolean isLanding() {
            return isLanding;
        }

        @Override
        public String toString() {
            return "HOVERING STATE: " + isHovering + " LANDING STATE: " + isLanding;
        }
    }
}


//~ Formatted by Jindent --- http://www.jindent.com
